import React, { useState } from 'react'
import ContentCss from './index.module.scss'
import Modal  from '../modal/Modal'
const Content = () => {

    const [visible, setVisible] = useState(false)
    const closeModal = () => {
        setVisible(false)
    }

    const showModal = () => {
        setVisible(true)
    }

    return (
        <div className={ContentCss.content}>
            <h1>
                A better way
            </h1>
            <h1>
                to enjoy every day
            </h1>
            <h3>
                Be the first know when we launch
            </h3>
            <div onClick={showModal} className={ContentCss.requestBtn}>
                submit request
            </div>
            { visible && <Modal closeModal={closeModal} /> }

        </div>
    )

}

export default Content